/*
 * @Author: your name
 * @Date: 2021-09-06 19:47:54
 * @LastEditTime: 2021-10-31 14:38:48
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \ej-customer-cli\src\store\category\category.js
 */
import { post, get } from '@/http/axios'
export default {
  namespaced: true,
  state: {
    categories:[]
  },
  mutations: {
    SET_CATGORY(state,payload){
      state.categories=payload
    }
  },
  actions: {
      async findAllCategory({commit}){
        let res =await get('/productCategory/pageQuery',{
          page:1,
          pageSize:10
        })
        commit('SET_CATGORY',res.data.data.list)
      }

  }
    
}